/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.ufrgs.inf.inf05005.automatos;

/**
 *
 * @author fkrahe
 */
public class AutomNode {

    private String nome;
    private boolean isFinal;

    public AutomNode(String nome) {
        this.nome = nome;
        this.isFinal = false;
    }

    public AutomNode(String nome, boolean isFinal) {
        this.nome = nome;
        this.isFinal = isFinal;
    }

    public void setIsFinal(boolean isFinal) {
        this.isFinal = isFinal;
    }

    public boolean isIsFinal() {
        return isFinal;
    }

    @Override
    public String toString() {
        return "AutomNode{" + "nome=" + nome + ", isFinal=" + isFinal + '}';
    }

    @Override
    public boolean equals(Object o) {
        if (!(o instanceof AutomNode)) {
            return false;
        }
        AutomNode node = (AutomNode) o;
        if (this.nome.equals(node.nome)) {
            return true;
        } else {
            return false;
        }
    }
}
